//
//  GameOverViewController.m
//  Flyer
//
//  Created by Brian Chung on 7/14/12.
//  Copyright (c) 2012 Stony Brook University Suny. All rights reserved.
//

#import "GameOverViewController.h"
#import "GameStartViewController.h"
#import "ViewController.h"
@interface GameOverViewController ()
@end

@implementation GameOverViewController
@synthesize gameStart;
@synthesize currentView;
- (void)viewDidLoad
{
    [super viewDidLoad];
    // Do any additional setup after loading the view from its nib.
}

- (void)viewDidUnload
{
    [super viewDidUnload];
    // Release any retained subviews of the main view.
    // e.g. self.myOutlet = nil;
}
-(IBAction)resetGame:(id)sender{
    if(self.gameStart==nil){
   self.gameStart=[[GameStartViewController alloc] initWithNibName:@"GameStartViewController" bundle:nil];
    }
    //[self.view insertSubview:self.gameStart.view atIndex:2];
    [gameStart setCurrentView:currentView];
    self.view=nil;
    [self.currentView.view addSubview:self.gameStart.view];
    //[self.view removeFromSuperview];
    
}
@end
